<%-- 
    Document   : addCenters
    Created on : 15 Nov, 2012, 7:26:05 PM
    Author     : sagar
--%>

<%@page contentType="text/html" pageEncoding="UTF-8"%>
<link type="text/css" href="css/main.css" rel="stylesheet" />
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=false"></script>
<%@include file="../common/script.jsp" %>
<script type="text/javascript" src="../js/googleMap.js" ></script>

<!DOCTYPE html>
<script type="text/javascript">
    var rules=new Array();
    rules[0]='centerName|required|Please Enter Center Name';
    rules[1]='address|required|Please Enter Address';
    rules[2]='masterZoneId|required|Please Select MasterZone';
    rules[3]='phoneNumber|required|Please Enter Phone Number';
    rules[4]='latitude|required|Required latitude pixel';
    rules[5]='longitude|required|Required longitude pixel';
    
    
</script>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <%@include file="../common/title.jsp" %>
    </head>
    <body onLoad="yav.init('form1',rules,'inline');">
        <%@include file="../common/header.jsp" %>
        <%@include file="../common/menu.jsp" %>
<!--        <div class="in_02">-->
<div style="width: 40%;  position: absolute; top:150px; left:20px; font:normal 12px/normal Arial;">
            <%@include file="../common/message.jsp" %>
            <form:form id="form1" name="form1" modelAttribute="center"  method="POST" >
                <fieldset>
                    <legend><spring:message code="title.addHealthspringCommunityMedicalCentres"/></legend>
                    <table class="formTable">
                        <tr>
                            <td><spring:message code="healthspringCommunityMedicalCenterName"/>:<br/>
                                <form:input path="centerName" id="centerName" cssClass="userInputLarge"/>
                                <br/><span id="errorsDiv_centerName"></span></td>

                            <td><spring:message code="address"/>:<br/>
                                <form:textarea path="address" id="address" cssClass="userInputLarge"/>
                                <br/><span id="errorsDiv_address"></span></td>
                        </tr>
                        <tr>
                            <td><spring:message code="masterZone"/>:<br/>
                                <form:select  path="masterZone.masterZoneId" id="masterZoneId" style="margin-bottom: 5px">
                                    <form:option value="" label="-"></form:option>
                                    <form:options items="${masterZoneList}" itemLabel="masterZoneDesc" itemValue="masterZoneId"></form:options>
                                </form:select>
                                <br/><span id="errorsDiv_masterZoneId"></span>
                            </td>
                            <td><spring:message code="phoneNumber"/>:<br/>
                                <form:input path="phoneNumber" id="phoneNumber"  cssClass="userInputLarge"/>
                                <br/><span id="errorsDiv_phoneNumber"></span></td>
                            
                        </tr>
                        
                        <tr style="display:none;">
                            <td>Latitude:<br/>
                                <form:input path="latitude" id="latitude" cssClass="userInputLarge"/>
                                <br/><span id="errorsDiv_latitude"></span></td>

                            <td>Longitude:<br/>
                                <form:input path="longitude" id="longitude" cssClass="userInputLarge"/>
                                <br/><span id="errorsDiv_longitude"></span></td>

                        </tr>

                        <tr>
                            <td><input type="button" name="btnCancel" value="<spring:message code="button.Cancel"/>" onclick="location.href='../centers/listCenters.htm'" /></td>   
                            <td><input type="submit" name="btnSubmit" value="<spring:message code="button.Add"/>" onclick="return yav.performCheck('form1', rules, 'inline');"/></td>

                        </tr>
                    </table>
                </fieldset>
            </form:form>
        </div>
        <div style="width: 50%;  position: absolute; top:150px; right:20px; font:normal 12px/normal Arial;">
            <div id="map_canvas"></div><br/>
        </div> 
    </body>
</html>

